home *** CD-ROM | disk | FTP | other *** search
/ Aminet 30 / Aminet 30 (1999)(Schatztruhe)[!][Apr 1999].iso / Aminet / dev / c / Storm_FlexCat.lha / Storm_FlexCat / C_c.sd next >
Text File  |  1999-02-18  |  1KB  |  64 lines

  1. ##stringtype C
  2. ##shortstrings
  3. /****************************************************************
  4.    This file was created automatically by `%fv'
  5.    from "%f0".
  6.  
  7.    Do NOT edit by hand!
  8. ****************************************************************/
  9.  
  10. /* Include files */
  11. #include <proto/locale.h>
  12.  
  13. #include "%b_Cat.h"
  14.  
  15. /* Variables */
  16. struct FC_String %b_Strings[] =
  17. {
  18.    { %s, %d },
  19.    { NULL, 0 }
  20. };
  21.  
  22. static struct Catalog *%bCatalog;
  23.  
  24.  
  25. void Open%bCatalog()
  26. {
  27.    if (LocaleBase)
  28.    {
  29.       if (%bCatalog = OpenCatalog(NULL, "%b.catalog",
  30.                            OC_BuiltInLanguage, %l,
  31.                            OC_Version, %v,
  32.                            TAG_DONE
  33.                                  )
  34.          )
  35.       {
  36.          struct FC_String *fc;
  37.  
  38.          for (fc = %b_Strings; fc->Str; fc++)
  39.          {
  40.             fc->Str = GetCatalogStr(%bCatalog, fc->Id, fc->Str);
  41.          }
  42.       }
  43.    }
  44. }
  45.  
  46. void Close%bCatalog()
  47. {
  48.    if (%bCatalog)
  49.    {
  50.       CloseCatalog(%bCatalog);
  51.    }
  52. }
  53.  
  54. void LocalizeStringArray(STRPTR *Array)
  55. {
  56.    STRPTR *x;
  57.  
  58.    for (x = Array; *x; x++)
  59.    {
  60.       *x = %b_Strings[(int)*x].Str;
  61.    }
  62. }
  63.  
  64.